package net.maku.module.staff.service.impl;

import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
import lombok.AllArgsConstructor;
import net.maku.module.staff.dao.StaffDao;
import net.maku.module.staff.entity.StaffEntity;
import net.maku.module.staff.service.StaffService;
import net.maku.newbase.NewBaseServiceImpl;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 业务_员工
 *
 * @author
 */
@Service
@AllArgsConstructor
public class StaffServiceImpl extends NewBaseServiceImpl<StaffDao, StaffEntity> implements StaffService {

    @Override
    public List findListByOrgId(Long orgId) {
        LambdaQueryWrapper<StaffEntity> queryWrapper = new LambdaQueryWrapper<>();
        queryWrapper.eq(StaffEntity::getOrganizationId, orgId);
        return dao.selectList(queryWrapper);
    }
}